#ifndef LEXER_H
#define LEXER_H
#include "Token.h"
#include <codecvt>

class Lexer
{
    std::string text;
    int pos;
    char current_char;
    bool ed = false;

public:
    Lexer() : text(), pos(0), current_char() {}
    Lexer(std::string txt) : text(txt), pos(0)
    {
        if (!txt.empty())
        {
            current_char = txt[0];
        }
    }

    inline bool stop() { return ed; }

    const std::string pick_id();

    Lexer &advance();

    char peek(int len = 1);

    void skip_comment();

    void skip_space();

    token gt();

    token lparen();

    token rparen();

    token lblock();

    token rblock();

    token txt();

    token background();

    token end();

    token rbracket();

    token lbracket();

    token next_token();

    token colon();

    token branch();

    token minus();
};
#endif